<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<%request.setAttribute("user", request.getAttribute("user")); %>
	<div >
		<h3>${user.username}</h3>
	</div>
	<table>
		<tr>
			<td>BookName</td>
			<td>BuyNum</td>
		</tr>
		<c:forEach items="${cartlist}" var="order"  varStatus="index">
		<tr>
			<td>${order.bookname }</td>
			<td>${order.count }</td>
		</tr>
		</c:forEach>
	</table>
	<div>
		<a href="sec/buy?type=buyall&userid=${user.id }&username=${user.username}">Buy All</a>
		<a href="sec/buy?type=buy&userid=${user.id }&username=${user.username}">Go Back</a>
	</div>
</body>
</html>